<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>时空胶囊 | 人生时光轴</title>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        :root {
            /* 沿用原配色方案 */
            --color01: #534739; /* 深棕色 */
            --color02: #9E8774; /* 棕褐色 */
            --color03: #F0F2F1; /* 米白色 */
            --color04: #1F2D33; /* 深青色 */
            --color05: #0D0D0C; /* 近黑色 */
            
            /* 玻璃质感 */
            --glass: rgba(240, 242, 241, 0.85);
            --glass-border: rgba(255, 255, 255, 0.4);
            --glass-shadow: rgba(83, 71, 57, 0.25);
            
            /* 动画效果 */
            --transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.1);
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
        }

        body {
            background: linear-gradient(135deg, #F0F2F1 0%, #e8eaea 100%);
            color: var(--color01);
            min-height: 100vh;
            overflow-x: hidden;
            padding: 0;
            background-image: url('');
        }

        .container {
            max-width: 1400px;
            margin: 0 auto;
            padding: 0 20px;
        }

        /* 顶部导航栏 - 保持一致的玻璃效果 */
        .navbar {
            position: sticky;
            top: 0;
            z-index: 100;
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 15px 30px;
            background: var(--glass);
            backdrop-filter: blur(12px) saturate(180%);
            -webkit-backdrop-filter: blur(12px) saturate(180%);
            border-radius: 0 0 20px 20px;
            margin-bottom: 20px;
            box-shadow: 0 4px 20px var(--glass-shadow);
            border: 1px solid var(--glass-border);
            border-top: none;
            transition: var(--transition);
        }

        .logo {
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .logo-icon {
            font-size: 28px;
            color: var(--color04);
            animation: pulse 2s infinite;
        }

        .logo-text {
            font-size: 24px;
            font-weight: 600;
            letter-spacing: 1px;
            background: linear-gradient(45deg, var(--color05), var(--color01));
            -webkit-background-clip: text;
            background-clip: text;
            -webkit-text-fill-color: transparent;
            position: relative;
        }

        /* 导航链接 */
        .nav-toggle {
            display: none;
            font-size: 24px;
            color: var(--color01);
            cursor: pointer;
            z-index: 101;
        }

        .nav-links {
            display: flex;
            gap: 20px;
        }

        .nav-link {
            text-decoration: none;
            color: var(--color01);
            font-size: 16px;
            font-weight: 500;
            padding: 8px 14px;
            border-radius: 50px;
            transition: var(--transition);
            position: relative;
        }

        .nav-link:hover {
            background: rgba(255, 255, 255, 0.3);
            color: var(--color04);
        }

        .nav-link.active {
            background: rgba(158, 135, 116, 0.2);
            color: var(--color04);
        }

        .nav-link.active::after {
            content: '';
            position: absolute;
            bottom: -6px;
            left: 50%;
            transform: translateX(-50%);
            width: 6px;
            height: 6px;
            background: var(--color04);
            border-radius: 50%;
        }

        .user-actions {
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .search-box {
            display: flex;
            align-items: center;
            background: rgba(255, 255, 255, 0.6);
            border-radius: 50px;
            padding: 6px 12px;
            transition: var(--transition);
        }

        .search-box:hover {
            background: rgba(255, 255, 255, 0.8);
            box-shadow: 0 0 15px rgba(158, 135, 116, 0.2);
        }

        .search-box input {
            background: transparent;
            border: none;
            outline: none;
            padding: 5px 10px;
            width: 160px;
            color: var(--color01);
            font-size: 15px;
        }

        .search-box i {
            color: var(--color02);
        }

        .user-profile {
            width: 40px;
            height: 40px;
            border-radius: 50%;
            background: linear-gradient(45deg, var(--color02), var(--color01));
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--color03);
            font-weight: bold;
            cursor: pointer;
            box-shadow: 0 4px 12px var(--glass-shadow);
            transition: var(--transition);
            position: relative;
            overflow: hidden;
        }

        .user-profile::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
            transition: 0.5s;
        }

        .user-profile:hover::before {
            left: 100%;
        }

        .user-profile:hover {
            transform: scale(1.05);
            box-shadow: 0 6px 18px rgba(83, 71, 57, 0.35);
        }

        /* 主内容区 */
        .main-content {
            margin-bottom: 40px;
        }

        /* 内容区 - 保持玻璃效果 */
        .content-area {
            background: var(--glass);
            backdrop-filter: blur(12px) saturate(180%);
            -webkit-backdrop-filter: blur(12px) saturate(180%);
            border-radius: 20px;
            padding: 30px;
            box-shadow: 0 8px 32px var(--glass-shadow);
            border: 1px solid var(--glass-border);
            animation: fadeIn 0.8s ease-out;
        }

        .section-header {
            margin-bottom: 30px;
            text-align: center;
            padding: 30px;
            background: rgba(255, 255, 255, 0.4);
            border-radius: 15px;
            backdrop-filter: blur(5px);
            border: 1px solid var(--glass-border);
            position: relative;
            overflow: hidden;
        }

        .section-header::after {
            content: '';
            position: absolute;
            top: -50%;
            left: -50%;
            width: 200%;
            height: 200%;
            background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, transparent 70%);
            animation: rotate 20s linear infinite;
            z-index: -1;
        }

        .section-title {
            font-size: 32px;
            margin-bottom: 12px;
            background: linear-gradient(45deg, var(--color05), var(--color01));
            -webkit-background-clip: text;
            background-clip: text;
            -webkit-text-fill-color: transparent;
            position: relative;
        }

        .section-subtitle {
            font-size: 18px;
            color: var(--color02);
            margin: 0 auto 25px;
            max-width: 800px;
            line-height: 1.6;
        }

        /* 快捷操作按钮 */
        .action-buttons {
            display: flex;
            justify-content: center;
            gap: 20px;
            margin-bottom: 15px;
            flex-wrap: wrap;
        }

        .action-btn {
            display: flex;
            align-items: center;
            gap: 8px;
            padding: 12px 25px;
            border-radius: 50px;
            background: linear-gradient(135deg, var(--color02), var(--color01));
            color: var(--color03);
            border: none;
            font-weight: 500;
            cursor: pointer;
            transition: var(--transition);
            box-shadow: 0 4px 12px var(--glass-shadow);
            position: relative;
            overflow: hidden;
            z-index: 1;
        }

        .action-btn::after {
            content: '';
            position: absolute;
            top: -50%;
            left: -60%;
            width: 20px;
            height: 200%;
            background: rgba(255,255,255,0.3);
            transform: rotate(25deg);
            transition: all 0.6s;
            z-index: -1;
        }

        .action-btn:hover::after {
            left: 120%;
        }

        .action-btn:hover {
            transform: translateY(-5px);
            box-shadow: 0 8px 20px rgba(83, 71, 57, 0.35);
        }

        .action-btn.secondary {
            background: transparent;
            color: var(--color01);
            border: 1px solid var(--color02);
        }

        .action-btn.secondary:hover {
            background: rgba(158, 135, 116, 0.15);
        }

        /* 时空胶囊创建区 */
        .create-capsule {
            background: rgba(255, 255, 255, 0.7);
            border-radius: 18px;
            padding: 30px;
            margin-bottom: 40px;
            box-shadow: 0 6px 20px var(--glass-shadow);
            border: 1px solid var(--glass-border);
            transition: var(--transition);
        }

        .create-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 25px;
        }

        .create-title {
            font-size: 22px;
            color: var(--color05);
            display: flex;
            align-items: center;
            gap: 10px;
        }

        .create-title i {
            color: var(--color02);
        }

        .capsule-form {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 25px;
        }

        .form-group {
            margin-bottom: 15px;
        }

        .form-label {
            display: block;
            margin-bottom: 8px;
            font-weight: 500;
            color: var(--color01);
        }

        .form-control {
            width: 100%;
            padding: 12px 15px;
            border-radius: 10px;
            border: 1px solid var(--glass-border);
            background: rgba(255, 255, 255, 0.6);
            font-size: 15px;
            color: var(--color01);
            transition: var(--transition);
        }

        .form-control:focus {
            outline: none;
            border-color: var(--color02);
            box-shadow: 0 0 0 3px rgba(158, 135, 116, 0.2);
        }

        textarea.form-control {
            min-height: 120px;
            resize: vertical;
            line-height: 1.6;
        }

        .form-hint {
            font-size: 13px;
            color: var(--color02);
            margin-top: 5px;
        }

        .media-upload {
            border: 2px dashed var(--color02);
            border-radius: 10px;
            padding: 30px;
            text-align: center;
            cursor: pointer;
            transition: var(--transition);
        }

        .media-upload:hover {
            background: rgba(158, 135, 116, 0.05);
            border-color: var(--color01);
        }

        .media-upload i {
            font-size: 36px;
            color: var(--color02);
            margin-bottom: 15px;
        }

        .media-upload p {
            color: var(--color01);
            margin-bottom: 5px;
        }

        .media-upload small {
            font-size: 13px;
            color: var(--color02);
        }

        .form-actions {
            grid-column: 1 / -1;
            display: flex;
            justify-content: flex-end;
            gap: 15px;
        }

        .btn {
            padding: 10px 25px;
            border-radius: 50px;
            font-weight: 500;
            cursor: pointer;
            transition: var(--transition);
            border: none;
        }

        .btn-primary {
            background: linear-gradient(135deg, var(--color02), var(--color01));
            color: var(--color03);
            box-shadow: 0 4px 12px var(--glass-shadow);
        }

        .btn-secondary {
            background: transparent;
            color: var(--color01);
            border: 1px solid var(--color02);
        }

        .btn:hover {
            transform: translateY(-3px);
            box-shadow: 0 6px 18px rgba(83, 71, 57, 0.3);
        }

        /* 胶囊分类 */
        .capsule-categories {
            margin-bottom: 40px;
        }

        .section-heading {
            font-size: 24px;
            color: var(--color05);
            position: relative;
            display: inline-block;
            margin-bottom: 25px;
        }

        .section-heading::after {
            content: '';
            position: absolute;
            bottom: -5px;
            left: 0;
            width: 50px;
            height: 3px;
            background: linear-gradient(90deg, var(--color02), var(--color01));
            border-radius: 2px;
        }

        .category-tabs {
            display: flex;
            gap: 10px;
            margin-bottom: 25px;
            overflow-x: auto;
            padding-bottom: 10px;
        }

        .category-tab {
            padding: 8px 20px;
            background: rgba(255, 255, 255, 0.6);
            border-radius: 50px;
            border: 1px solid var(--glass-border);
            white-space: nowrap;
            cursor: pointer;
            transition: var(--transition);
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .category-tab.active {
            background: linear-gradient(135deg, var(--color02), var(--color01));
            color: var(--color03);
            border-color: var(--color02);
        }

        .category-tab:hover:not(.active) {
            background: rgba(255, 255, 255, 0.8);
            transform: translateY(-2px);
        }

        /* 时空胶囊列表 */
        .capsules-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
            gap: 25px;
            margin-bottom: 40px;
        }

        .capsule-card {
            background: rgba(255, 255, 255, 0.8);
            border-radius: 18px;
            overflow: hidden;
            box-shadow: 0 6px 20px var(--glass-shadow);
            border: 1px solid var(--glass-border);
            transition: var(--transition);
            position: relative;
        }

        .capsule-card.future::before {
            content: '未开启';
            position: absolute;
            top: 15px;
            left: 15px;
            background: rgba(31, 45, 51, 0.8);
            color: white;
            padding: 4px 10px;
            border-radius: 20px;
            font-size: 12px;
            backdrop-filter: blur(5px);
        }

        .capsule-card.past::before {
            content: '已开启';
            position: absolute;
            top: 15px;
            left: 15px;
            background: rgba(98, 160, 89, 0.8);
            color: white;
            padding: 4px 10px;
            border-radius: 20px;
            font-size: 12px;
            backdrop-filter: blur(5px);
        }

        .capsule-card:hover {
            transform: translateY(-8px);
            box-shadow: 0 15px 35px var(--glass-shadow);
        }

        .capsule-image {
            height: 180px;
            overflow: hidden;
            position: relative;
        }

        .capsule-image img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            transition: transform 0.6s ease;
        }

        .capsule-card:hover .capsule-image img {
            transform: scale(1.05);
        }

        .capsule-content {
            padding: 20px;
        }

        .capsule-date {
            font-size: 14px;
            color: var(--color02);
            margin-bottom: 8px;
            display: flex;
            align-items: center;
            gap: 6px;
        }

        .capsule-title {
            font-size: 18px;
            font-weight: 600;
            margin-bottom: 10px;
            color: var(--color05);
            line-height: 1.4;
        }

        .capsule-description {
            font-size: 15px;
            color: var(--color01);
            line-height: 1.6;
            margin-bottom: 15px;
            display: -webkit-box;
            -webkit-line-clamp: 3;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .capsule-meta {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding-top: 15px;
            border-top: 1px dashed rgba(158, 135, 116, 0.3);
        }

        .capsule-type {
            font-size: 13px;
            padding: 4px 12px;
            border-radius: 20px;
            background: rgba(158, 135, 116, 0.15);
            color: var(--color01);
        }

        .capsule-actions {
            display: flex;
            gap: 10px;
        }

        .capsule-action {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--color02);
            background: rgba(255, 255, 255, 0.6);
            border: 1px solid var(--glass-border);
            cursor: pointer;
            transition: var(--transition);
        }

        .capsule-action:hover {
            background: white;
            color: var(--color01);
            transform: translateY(-2px);
        }

        /* 时间线 */
        .timeline-view {
            margin-bottom: 40px;
            padding: 30px;
            background: rgba(255, 255, 255, 0.7);
            border-radius: 18px;
            box-shadow: 0 6px 20px var(--glass-shadow);
            border: 1px solid var(--glass-border);
        }

        .timeline-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 30px;
        }

        .timeline-title {
            font-size: 20px;
            color: var(--color05);
            display: flex;
            align-items: center;
            gap: 10px;
        }

        .timeline-title i {
            color: var(--color02);
        }

        .timeline {
            position: relative;
            padding: 20px 0;
        }

        .timeline::before {
            content: '';
            position: absolute;
            left: 50%;
            top: 0;
            height: 100%;
            width: 4px;
            background: linear-gradient(to bottom, var(--color02), var(--color01));
            border-radius: 2px;
            transform: translateX(-50%);
        }

        .timeline-point {
            position: relative;
            margin-bottom: 40px;
            display: flex;
            justify-content: flex-end;
            padding-right: calc(50% + 30px);
        }

        .timeline-point:nth-child(even) {
            justify-content: flex-start;
            padding-right: 0;
            padding-left: calc(50% + 30px);
        }

        .timeline-point:last-child {
            margin-bottom: 0;
        }

        .timeline-dot {
            position: absolute;
            left: 50%;
            top: 0;
            width: 20px;
            height: 20px;
            border-radius: 50%;
            background: var(--color03);
            border: 4px solid var(--color02);
            z-index: 1;
            transform: translateX(-50%);
        }

        .timeline-content {
            background: white;
            border-radius: 15px;
            padding: 15px;
            width: 100%;
            max-width: 350px;
            box-shadow: 0 4px 15px var(--glass-shadow);
            border: 1px solid var(--glass-border);
        }

        .timeline-date {
            font-size: 14px;
            font-weight: 600;
            color: var(--color02);
            margin-bottom: 5px;
        }

        .timeline-title-small {
            font-size: 16px;
            font-weight: 600;
            color: var(--color05);
            margin-bottom: 5px;
        }

        /* 动画定义 */
        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(20px); }
            to { opacity: 1; transform: translateY(0); }
        }

        @keyframes pulse {
            0% { transform: scale(1); }
            50% { transform: scale(1.1); }
            100% { transform: scale(1); }
        }

        @keyframes rotate {
            from { transform: rotate(0deg); }
            to { transform: rotate(360deg); }
        }

        /* 响应式设计 */
        @media (max-width: 1024px) {
            .nav-links {
                gap: 15px;
            }

            .nav-link {
                font-size: 15px;
                padding: 6px 12px;
            }

            .timeline-content {
                max-width: 300px;
            }
        }

        @media (max-width: 768px) {
            .nav-toggle {
                display: block;
            }

            .nav-links {
                position: fixed;
                top: 80px;
                right: -100%;
                flex-direction: column;
                background: var(--glass);
                backdrop-filter: blur(12px) saturate(180%);
                padding: 25px 30px;
                border-radius: 15px 0 0 15px;
                box-shadow: -5px 0 15px var(--glass-shadow);
                transition: right 0.4s ease;
                z-index: 99;
                border: 1px solid var(--glass-border);
                gap: 15px;
            }

            .nav-links.active {
                right: 0;
            }

            .content-area {
                padding: 20px;
            }
            
            .section-header {
                padding: 25px 15px;
            }
            
            .section-title {
                font-size: 28px;
            }
            
            .section-subtitle {
                font-size: 16px;
            }

            .form-actions {
                grid-column: 1;
                flex-direction: column;
            }

            .timeline::before {
                left: 30px;
            }

            .timeline-point {
                padding-right: 0;
                padding-left: 70px;
                justify-content: flex-start;
            }

            .timeline-point:nth-child(even) {
                padding-left: 70px;
            }

            .timeline-dot {
                left: 30px;
            }

            .timeline-content {
                max-width: 100%;
            }
        }

        @media (max-width: 480px) {
            .navbar {
                padding: 12px 15px;
            }

            .logo-text {
                font-size: 20px;
            }

            .search-box {
                display: none;
            }

            .section-title {
                font-size: 24px;
            }

            .action-buttons {
                gap: 12px;
            }

            .action-btn {
                padding: 10px 20px;
                font-size: 14px;
            }
            
            .nav-links {
                top: 70px;
            }

            .capsule-form {
                grid-template-columns: 1fr;
            }

            .media-upload {
                padding: 20px 10px;
            }

            .category-tabs {
                gap: 8px;
            }

            .category-tab {
                padding: 6px 15px;
                font-size: 14px;
            }

            .capsules-grid {
                grid-template-columns: 1fr;
            }

            .timeline-view {
                padding: 20px 15px;
            }

            .timeline-point {
                padding-left: 50px;
            }

            .timeline::before {
                left: 20px;
            }

            .timeline-dot {
                left: 20px;
                width: 16px;
                height: 16px;
                border-width: 3px;
            }
        }
    </style>
</head>

<body>
    <div class="container">
        <!-- 顶部导航栏 -->
        <nav class="navbar">
            <div class="logo">
                <div class="logo-icon">
                    <i class="fas fa-hourglass-half"></i>
                </div>
                <div class="logo-text">人生时光轴</div>
            </div>

            <!-- 移动端菜单按钮 -->
            <div class="nav-toggle">
                <i class="fas fa-bars"></i>
            </div>

            <div class="nav-links">
                <a href="#" class="nav-link">时光轨迹</a>
                <a href="#" class="nav-link">生命记录</a>
                <a href="#" class="nav-link">记忆中心</a>
                <a href="#" class="nav-link">蓝图规划</a>
                <a href="#" class="nav-link">人物自传</a>
                <a href="#" class="nav-link active">时空胶囊</a>
            </div>

            <div class="user-actions">
                <div class="search-box">
                    <i class="fas fa-search"></i>
                    <input type="text" placeholder="搜索胶囊...">
                </div>
                <div class="user-profile">S</div>
            </div>
        </nav>

        <!-- 主内容区 -->
        <div class="main-content">
            <!-- 内容区 -->
            <div class="content-area">
                <div class="section-header">
                    <h1 class="section-title">时空胶囊</h1>
                    <p class="section-subtitle">将此刻的心情、想法和珍贵回忆封存，设定未来的开启时间，给未来的自己或他人一个惊喜。时间会流逝，但记忆可以被珍藏。</p>

                    <div class="action-buttons">
                        <button class="action-btn" id="openCreateForm">
                            <i class="fas fa-box"></i> 创建新胶囊
                        </button>
                        <button class="action-btn secondary">
                            <i class="fas fa-map-marker-alt"></i> 胶囊位置
                        </button>
                        <button class="action-btn secondary">
                            <i class="fas fa-history"></i> 开启记录
                        </button>
                    </div>
                </div>

                <!-- 创建时空胶囊 -->
                <div class="create-capsule">
                    <div class="create-header">
                        <h3 class="create-title"><i class="fas fa-pen-fancy"></i> 封存此刻的记忆</h3>
                    </div>
                    <form class="capsule-form">
                        <div class="form-group">
                            <label class="form-label">胶囊标题</label>
                            <input type="text" class="form-control" placeholder="给你的时空胶囊起个名字">
                            <p class="form-hint">简洁明了的标题有助于未来快速识别</p>
                        </div>

                        <div class="form-group">
                            <label class="form-label">开启时间</label>
                            <input type="date" class="form-control">
                            <p class="form-hint">选择未来的某一天开启这个胶囊</p>
                        </div>

                        <div class="form-group">
                            <label class="form-label">胶囊类型</label>
                            <select class="form-control">
                                <option value="personal">个人回忆</option>
                                <option value="message">给未来的信</option>
                                <option value="goal">目标与承诺</option>
                                <option value="gift">给他人的礼物</option>
                                <option value="event">特定事件纪念</option>
                            </select>
                        </div>

                        <div class="form-group">
                            <label class="form-label">接收者</label>
                            <select class="form-control">
                                <option value="self">未来的自己</option>
                                <option value="friend">朋友</option>
                                <option value="family">家人</option>
                                <option value="lover">爱人</option>
                                <option value="public">公开胶囊</option>
                            </select>
                        </div>

                        <div class="form-group">
                            <label class="form-label">胶囊内容</label>
                            <textarea class="form-control" placeholder="写下你想对未来说的话..."></textarea>
                            <p class="form-hint">可以记录此刻的心情、想法、目标或任何想保存的记忆</p>
                        </div>

                        <div class="form-group">
                            <label class="form-label">添加附件</label>
                            <div class="media-upload">
                                <i class="fas fa-cloud-upload-alt"></i>
                                <p>点击上传图片、视频或文件</p>
                                <small>支持JPG、PNG、MP4、PDF格式，最大20MB</small>
                            </div>
                        </div>

                        <div class="form-actions">
                            <button type="button" class="btn btn-secondary">保存草稿</button>
                            <button type="button" class="btn btn-primary">封存胶囊</button>
                        </div>
                    </form>
                </div>

                <!-- 胶囊分类 -->
                <div class="capsule-categories">
                    <h2 class="section-heading">我的时空胶囊</h2>
                    <div class="category-tabs">
                        <div class="category-tab active">
                            <i class="fas fa-th"></i> 全部胶囊
                        </div>
                        <div class="category-tab">
                            <i class="fas fa-clock"></i> 未开启
                        </div>
                        <div class="category-tab">
                            <i class="fas fa-check-circle"></i> 已开启
                        </div>
                        <div class="category-tab">
                            <i class="fas fa-user"></i> 个人回忆
                        </div>
                        <div class="category-tab">
                            <i class="fas fa-envelope"></i> 给未来的信
                        </div>
                        <div class="category-tab">
                            <i class="fas fa-bullseye"></i> 目标与承诺
                        </div>
                        <div class="category-tab">
                            <i class="fas fa-gift"></i> 给他人的礼物
                        </div>
                    </div>

                    <!-- 胶囊列表 -->
                    <div class="capsules-grid">
                        <div class="capsule-card future">
                            <div class="capsule-image">
                                <img src="https://images.unsplash.com/photo-1581362346609-084a45276324?ixlib=rb-4.0.3&auto=format&fit=crop&w=600&q=80" alt="30岁生日胶囊">
                            </div>
                            <div class="capsule-content">
                                <div class="capsule-date"><i class="fas fa-calendar-alt"></i> 设定开启: 2025年6月15日</div>
                                <h3 class="capsule-title">给30岁的自己</h3>
                                <p class="capsule-description">记录25岁时的生活状态、梦想和困惑，希望5年后的自己看到时，能有所感悟和收获。</p>
                                <div class="capsule-meta">
                                    <span class="capsule-type">给未来的信</span>
                                    <div class="capsule-actions">
                                        <div class="capsule-action" title="查看详情">
                                            <i class="fas fa-eye"></i>
                                        </div>
                                        <div class="capsule-action" title="编辑">
                                            <i class="fas fa-edit"></i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="capsule-card past">
                            <div class="capsule-image">
                                <img src="https://images.unsplash.com/photo-1528360983277-13d401cdc186?ixlib=rb-4.0.3&auto=format&fit=crop&w=600&q=80" alt="大学毕业胶囊">
                            </div>
                            <div class="capsule-content">
                                <div class="capsule-date"><i class="fas fa-calendar-alt"></i> 已开启: 2023年6月30日</div>
                                <h3 class="capsule-title">大学毕业纪念</h3>
                                <p class="capsule-description">毕业那天封存的记忆，包含了对未来的憧憬、同学的留言和当时的照片。五年后开启，感慨万千。</p>
                                <div class="capsule-meta">
                                    <span class="capsule-type">特定事件纪念</span>
                                    <div class="capsule-actions">
                                        <div class="capsule-action" title="查看详情">
                                            <i class="fas fa-eye"></i>
                                        </div>
                                        <div class="capsule-action" title="分享">
                                            <i class="fas fa-share-alt"></i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="capsule-card future">
                            <div class="capsule-image">
                                <img src="https://images.unsplash.com/photo-1531512073830-ba890ca4eba2?ixlib=rb-4.0.3&auto=format&fit=crop&w=600&q=80" alt="五年计划胶囊">
                            </div>
                            <div class="capsule-content">
                                <div class="capsule-date"><i class="fas fa-calendar-alt"></i> 设定开启: 2028年1月1日</div>
                                <h3 class="capsule-title">五年计划与目标</h3>
                                <p class="capsule-description">记录了2023年时设定的五年目标，包括职业发展、旅行计划、学习目标等，期待2028年开启时检查完成情况。</p>
                                <div class="capsule-meta">
                                    <span class="capsule-type">目标与承诺</span>
                                    <div class="capsule-actions">
                                        <div class="capsule-action" title="查看详情">
                                            <i class="fas fa-eye"></i>
                                        </div>
                                        <div class="capsule-action" title="编辑">
                                            <i class="fas fa-edit"></i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="capsule-card future">
                            <div class="capsule-image">
                                <img src="https://images.unsplash.com/photo-1518655048521-f130df041f66?ixlib=rb-4.0.3&auto=format&fit=crop&w=600&q=80" alt="给孩子的信">
                            </div>
                            <div class="capsule-content">
                                <div class="capsule-date"><i class="fas fa-calendar-alt"></i> 设定开启: 2035年1月1日</div>
                                <h3 class="capsule-title">给18岁的孩子</h3>
                                <p class="capsule-description">写给未来孩子18岁生日的信，记录了现在的期待和祝福，希望那时他/她能理解父母的爱。</p>
                                <div class="capsule-meta">
                                    <span class="capsule-type">给他人的礼物</span>
                                    <div class="capsule-actions">
                                        <div class="capsule-action" title="查看详情">
                                            <i class="fas fa-eye"></i>
                                        </div>
                                        <div class="capsule-action" title="编辑">
                                            <i class="fas fa-edit"></i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="capsule-card past">
                            <div class="capsule-image">
                                <img src="https://images.unsplash.com/photo-1544117519-31a408c0766d?ixlib=rb-4.0.3&auto=format&fit=crop&w=600&q=80" alt="结婚纪念">
                            </div>
                            <div class="capsule-content">
                                <div class="capsule-date"><i class="fas fa-calendar-alt"></i> 已开启: 2022年10月1日</div>
                                <h3 class="capsule-title">结婚五周年纪念</h3>
                                <p class="capsule-description">结婚当天封存的胶囊，记录了对婚姻的期待和承诺。五年后与爱人一起开启，重温初心。</p>
                                <div class="capsule-meta">
                                    <span class="capsule-type">个人回忆</span>
                                    <div class="capsule-actions">
                                        <div class="capsule-action" title="查看详情">
                                            <i class="fas fa-eye"></i>
                                        </div>
                                        <div class="capsule-action" title="分享">
                                            <i class="fas fa-share-alt"></i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="capsule-card future">
                            <div class="capsule-image">
                                <img src="https://images.unsplash.com/photo-1522202176988-66273c2fd55f?ixlib=rb-4.0.3&auto=format&fit=crop&w=600&q=80" alt="事业里程碑">
                            </div>
                            <div class="capsule-content">
                                <div class="capsule-date"><i class="fas fa-calendar-alt"></i> 设定开启: 2030年12月31日</div>
                                <h3 class="capsule-title">事业十年规划</h3>
                                <p class="capsule-description">记录30岁时的职业状态和未来十年的职业规划，包含了想达成的目标和想学习的技能。</p>
                                <div class="capsule-meta">
                                    <span class="capsule-type">目标与承诺</span>
                                    <div class="capsule-actions">
                                        <div class="capsule-action" title="查看详情">
                                            <i class="fas fa-eye"></i>
                                        </div>
                                        <div class="capsule-action" title="编辑">
                                            <i class="fas fa-edit"></i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- 时间线视图 -->
                <div class="timeline-view">
                    <div class="timeline-header">
                        <h3 class="timeline-title"><i class="fas fa-stream"></i> 时间线上的胶囊</h3>
                        <button class="btn btn-secondary">切换视图</button>
                    </div>
                    <div class="timeline">
                        <div class="timeline-point">
                            <div class="timeline-dot"></div>
                            <div class="timeline-content">
                                <div class="timeline-date">2018年6月30日</div>
                                <div class="timeline-title-small">大学毕业纪念</div>
                                <p class="form-hint">已开启 · 特定事件纪念</p>
                            </div>
                        </div>

                        <div class="timeline-point">
                            <div class="timeline-dot"></div>
                            <div class="timeline-content">
                                <div class="timeline-date">2020年10月1日</div>
                                <div class="timeline-title-small">结婚纪念</div>
                                <p class="form-hint">已开启 · 个人回忆</p>
                            </div>
                        </div>

                        <div class="timeline-point">
                            <div class="timeline-dot"></div>
                            <div class="timeline-content">
                                <div class="timeline-date">2023年6月15日</div>
                                <div class="timeline-title-small">给30岁的自己</div>
                                <p class="form-hint">2025年6月15日开启 · 给未来的信</p>
                            </div>
                        </div>

                        <div class="timeline-point">
                            <div class="timeline-dot"></div>
                            <div class="timeline-content">
                                <div class="timeline-date">2023年12月31日</div>
                                <div class="timeline-title-small">五年计划与目标</div>
                                <p class="form-hint">2028年1月1日开启 · 目标与承诺</p>
                            </div>
                        </div>

                        <div class="timeline-point">
                            <div class="timeline-dot"></div>
                            <div class="timeline-content">
                                <div class="timeline-date">2023年12月31日</div>
                                <div class="timeline-title-small">给18岁的孩子</div>
                                <p class="form-hint">2035年1月1日开启 · 给他人的礼物</p>
                            </div>
                        </div>

                        <div class="timeline-point">
                            <div class="timeline-dot"></div>
                            <div class="timeline-content">
                                <div class="timeline-date">2023年12月31日</div>
                                <div class="timeline-title-small">事业十年规划</div>
                                <p class="form-hint">2030年12月31日开启 · 目标与承诺</p>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <script>
        // 移动端导航菜单切换
        const navToggle = document.querySelector('.nav-toggle');
        const navLinks = document.querySelector('.nav-links');

        navToggle.addEventListener('click', () => {
            navToggle.querySelector('i').classList.toggle('fa-bars');
            navToggle.querySelector('i').classList.toggle('fa-times');
            navLinks.classList.toggle('active');
        });

        // 导航链接激活状态切换
        document.querySelectorAll('.nav-link').forEach(link => {
            link.addEventListener('click', function (e) {
                e.preventDefault();
                document.querySelectorAll('.nav-link').forEach(el => {
                    el.classList.remove('active');
                });
                this.classList.add('active');

                // 移动端点击后关闭菜单
                if (window.innerWidth <= 768) {
                    navLinks.classList.remove('active');
                    navToggle.querySelector('i').classList.add('fa-bars');
                    navToggle.querySelector('i').classList.remove('fa-times');
                }
            });
        });

        // 分类标签切换
        document.querySelectorAll('.category-tab').forEach(tab => {
            tab.addEventListener('click', function() {
                document.querySelectorAll('.category-tab').forEach(t => {
                    t.classList.remove('active');
                });
                this.classList.add('active');
            });
        });

        // 胶囊卡片悬停效果
        document.querySelectorAll('.capsule-card').forEach(card => {
            card.addEventListener('mouseenter', function () {
                this.style.transform = 'translateY(-8px)';
            });

            card.addEventListener('mouseleave', function () {
                this.style.transform = 'translateY(0)';
            });
        });

        // 打开创建胶囊表单
        document.getElementById('openCreateForm').addEventListener('click', function() {
            const createForm = document.querySelector('.create-capsule');
            createForm.scrollIntoView({ behavior: 'smooth' });
            createForm.style.boxShadow = '0 10px 30px rgba(83, 71, 57, 0.3)';
            setTimeout(() => {
                createForm.style.boxShadow = '0 6px 20px var(--glass-shadow)';
            }, 1000);
        });

        // 媒体上传区域交互
        document.querySelector('.media-upload').addEventListener('click', function() {
            alert('打开文件选择器（实际应用中会触发文件上传对话框）');
        });

        // 胶囊操作按钮交互
        document.querySelectorAll('.capsule-action').forEach(action => {
            action.addEventListener('click', function(e) {
                e.stopPropagation();
                const icon = this.querySelector('i');
                const actionName = this.title;
                const capsuleTitle = this.closest('.capsule-card').querySelector('.capsule-title').textContent;
                
                if (actionName === '查看详情') {
                    alert(`查看 "${capsuleTitle}" 的详细内容`);
                } else if (actionName === '编辑') {
                    alert(`编辑 "${capsuleTitle}"`);
                } else if (actionName === '分享') {
                    alert(`分享 "${capsuleTitle}"`);
                }
            });
        });

        // 胶囊卡片点击事件
        document.querySelectorAll('.capsule-card').forEach(card => {
            card.addEventListener('click', function() {
                const title = this.querySelector('.capsule-title').textContent;
                alert(`打开胶囊: ${title}`);
            });
        });

        // 滚动时导航栏效果变化
        window.addEventListener('scroll', () => {
            const navbar = document.querySelector('.navbar');
            if (window.scrollY > 10) {
                navbar.style.boxShadow = '0 6px 25px rgba(83, 71, 57, 0.25)';
                navbar.style.backdropFilter = 'blur(16px) saturate(180%)';
            } else {
                navbar.style.boxShadow = '0 4px 20px var(--glass-shadow)';
                navbar.style.backdropFilter = 'blur(12px) saturate(180%)';
            }
        });

        // 表单提交事件
        document.querySelector('.btn-primary').addEventListener('click', function(e) {
            e.preventDefault();
            const title = document.querySelector('.capsule-form input[type="text"]').value || '未命名胶囊';
            alert(`胶囊 "${title}" 已成功封存！`);
        });

        document.querySelector('.btn-secondary').addEventListener('click', function(e) {
            e.preventDefault();
            const title = document.querySelector('.capsule-form input[type="text"]').value || '未命名胶囊';
            alert(`胶囊 "${title}" 已保存为草稿`);
        });

        // 时间线动画效果
        const animateTimeline = () => {
            const timelinePoints = document.querySelectorAll('.timeline-point');
            
            timelinePoints.forEach((point, index) => {
                const pointTop = point.getBoundingClientRect().top;
                const windowHeight = window.innerHeight;
                
                if (pointTop < windowHeight * 0.85) {
                    setTimeout(() => {
                        point.style.opacity = '1';
                        point.style.transform = 'translateY(0)';
                    }, index * 150);
                }
            });
        };
        
        // 初始设置
        document.querySelectorAll('.timeline-point').forEach(point => {
            point.style.opacity = '0';
            point.style.transform = 'translateY(20px)';
            point.style.transition = 'opacity 0.5s ease, transform 0.5s ease';
        });
        
        // 页面加载和滚动时触发动画
        window.addEventListener('load', animateTimeline);
        window.addEventListener('scroll', animateTimeline);
    </script>
</body>
</html>
